<!DOCTYPE HTML>
<html>
<head>
<title>PhoneGap</title>
	<link rel="stylesheet" type="text/css" href="style.css" />
</head>
<body>
	<!-- Button -->
	<input disabled id="btn-load" type="button"
		value="Load" />
	<hr>
		
	<!-- Place Holder for placing the SD Card Listing -->
	<div id="result"></div>
	<hr>

	<script type="text/javascript" src="phonegap-0.9.3.js"></script>
	<script type="text/javascript" src="serverbrowsing.js"></script>	
	<script type="text/javascript">
	
		document.addEventListener('deviceready', function() {
			var btn_load = document.getElementById("btn-load");
						
			btn_load.onclick = function() {
					listDMSServer();		
			}
	
			btn_load.disabled = false;			
	
		}, true);

		function listDMSServer(){
			console.log("list DMSServer ...");
			window.plugins.serverbrowsing.list("",
					function(r){
						console.log("Result: " + r);
					},
					function(e){
						console.log(e);
					});
		}
				
		function printResult(fileInfo) {
			var innerHtmlText = getHtml(fileInfo);
			document.getElementById("result").innerHTML = innerHtmlText;
		}

	</script>
</body>

</html>